/* 全局样式 */
:root {
    --primary-color: #007AFF;
    --background-color: #F5F5F7;
    --card-background: #FFFFFF;
    --text-color: #1D1D1F;
    --border-radius: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.5;   
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* 头部样式 */
header {
    text-align: center;
    margin-bottom: 2rem;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

header p {
    color: #666;
}

/* 上传区域样式 */
.upload-area {
    background: var(--card-background);
    border-radius: var(--border-radius);
    padding: 2rem;
    text-align: center;
    border: 2px dashed #ddd;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 2rem;
}

.upload-area:hover {
    border-color: var(--primary-color);
}

.upload-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.upload-icon {
    width: 48px;
    height: 48px;
    fill: var(--primary-color);
}

.upload-hint {
    color: #666;
    font-size: 0.9rem;
}

/* 压缩控制区域样式 */
.compression-controls {
    background: var(--card-background);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.quality-control {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

input[type="range"] {
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    background: #ddd;
    border-radius: 3px;
    outline: none;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
}

/* 预览区域样式 */
.preview-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.preview-box {
    background: var(--card-background);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    text-align: center;
}

.image-container {
    margin: 1rem 0;
    border-radius: var(--border-radius);
    overflow: hidden;
}

.image-container img {
    max-width: 100%;
    height: auto;
}

.file-info {
    color: #666;
    margin-bottom: 1rem;
}

.download-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.8rem 1.5rem;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 1rem;
    transition: opacity 0.3s ease;
}

.download-btn:hover {
    opacity: 0.9;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }
    
    header h1 {
        font-size: 2rem;
    }
} 